package com.lanou.mapper;

import com.lanou.entity.Course;
import com.lanou.entity.CourseQuery;
import com.lanou.entity.UserSearchRecord;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @ClassName CourseMapper
 * @Description TODO
 * @Author cuipengwei
 * @Date 2025年08月13日 11:08
 * @Version 1.0
 */
@Mapper
public interface CourseMapper {
    //查询全部
    List<Course> selectAll();
    //分页多条件查询
    List<Course> selectAllByName(Course course);
    //增加
    Integer addCourse(Course course);
    //删除
    Integer deleteCourse(Integer id);
    //修改
    Integer updateCourse(Course course);
    //根据id查询
    Course getCourseId(Integer id);

    //根据价格顺序或者区间排序分页获取
    List<Course> selectCourseBySort(CourseQuery courseQuery);
}
